
/**
 * @api {POST} /return_goods 退货结算（无订单退款）
 * @apiSampleRequest /return_goods
 * @apiDescription <div>refund_amount，值为正数时为用户支付，负数时为给用户找零。</div>
 * @apiGroup cart
 * @apiUse cart
 * @apiParam {String} bill_num 退货单号
 * @apiParam {Number} member_id 会员ID
 * @apiParam {Number} [refund_amount=0] 收银员输入的退款金额
 * @apiSuccess {Object} /data 数据
 * @apiSuccessExample {json} 成功响应：
 * HTTP/1.1 200 OK
 * {
 *     "errcode": 0,
 *     "order_data": {
 *         "goods_num": "1.000",
 *         "cart_total_price": "5",
 *         "created": 1638326246,
 *         "updated": 1638326246,
 *         "shop_id": 70,
 *         "cashier_id": 7,
 *         "order_sn": "211201103726418043131GOR",
 *         "bill_num": "271637808929716",
 *         "pay_method": "现金",
 *         "member_id": 0,
 *         "account": "",
 *         "status": -5, // 订单状态，0待支付，1已结，-1退货，-2退货子单，-3支付失败(需主动查询支付状态)，-4已退款，-5退换货，-100反结账(整单退)
 *         "remark": "",
 *         "cart_typ": 3,
 *         "total_price": "5"
 *     },
 *     "order_detail": [
 *         {
 *             "order_id": 787,
 *             "goods_id": 1570,
 *             "goods_name": "小米锅巴（大袋）",
 *             "barcode": "6970411499226",
 *             "amount": "2.000",
 *             "selling_price": "5.00",
 *             "spec_typ": 0,
 *             "is_input_price": 0,
 *             "is_discount": 0,
 *             "subtotal_raw": "10.00000",
 *             "subtotal": "10.00",
 *             "stock_prev": "4.000",
 *             "stock_next": "2.000",
 *             "status": -5, // -4无单退货,-5无单换货
 *             "created": 1638326246,
 *             "updated": 1638326246
 *         },
 *         {
 *             "order_id": 787,
 *             "goods_id": 1570,
 *             "goods_name": "小米锅巴（大袋）",
 *             "barcode": "6970411499226",
 *             "amount": "-1.000",
 *             "selling_price": "5.00",
 *             "spec_typ": 0,
 *             "is_input_price": 0,
 *             "is_discount": 0,
 *             "subtotal_raw": "-5.00000",
 *             "subtotal": "-5.00",
 *             "stock_prev": "2.000",
 *             "stock_next": "3.000",
 *             "status": -4,
 *             "created": 1638326246,
 *             "updated": 1638326246
 *         }
 *     ],
 *     "shop": {
 *         "shop_name": "新天地超市",
 *         "shop_phone": "13444444444",
 *         "shop_address": "太原街18号"
 *     },
 *     "refund_amount": "5"
 * }
 */

/**
 * @api {POST} /v3/return_goods 退货结算V3（无订单退款）组合支付
 * @apiSampleRequest /v3/return_goods
 * @apiDescription <div>refund_amount，值为正数时为用户支付，负数时为给用户找零。</div>
 * @apiGroup cart
 * @apiUse cart
 * @apiParam {String} bill_num 退货单号
 * @apiParam {Number} [refund_amount=0] 收银员输入的退款金额
 * @apiParam {Object[]} pay_methods 支付方式
 * @apiParam {Number} pay_methods.typ 支付方式类型 1现金，2仓储卡，3余额，10线下扫码，100微信/支付宝
 * @apiParam {String} pay_methods.amount 支付金额
 * @apiParam {Number} member_id 会员ID，支付类型为仓储卡时，需要传入会员ID
 * @apiParam {String} [pay_code=None] 支付码，如果支付方式包括“微信”或“支付宝”，则需要提供此参数
 * @apiSuccess {Object} /data 数据
 * @apiSuccessExample {json} 成功响应：
 * HTTP/1.1 200 OK
 * {
 *     "errcode": 0,
 *     "order_data": {
 *         "goods_num": "1.000",
 *         "cart_total_price": "5",
 *         "created": 1638326246,
 *         "updated": 1638326246,
 *         "shop_id": 70,
 *         "cashier_id": 7,
 *         "order_sn": "211201103726418043131GOR",
 *         "bill_num": "271637808929716",
 *         "pay_method": "现金",
 *         "member_id": 0,
 *         "account": "",
 *         "status": -5, // 订单状态，0待支付，1已结，-1退货，-2退货子单，-3支付失败(需主动查询支付状态)，-4已退款，-5退换货，-100反结账(整单退)
 *         "remark": "",
 *         "cart_typ": 3,
 *         "total_price": "5"
 *     },
 *     "order_detail": [
 *         {
 *             "order_id": 787,
 *             "goods_id": 1570,
 *             "goods_name": "小米锅巴（大袋）",
 *             "barcode": "6970411499226",
 *             "amount": "2.000",
 *             "selling_price": "5.00",
 *             "spec_typ": 0,
 *             "is_input_price": 0,
 *             "is_discount": 0,
 *             "subtotal_raw": "10.00000",
 *             "subtotal": "10.00",
 *             "stock_prev": "4.000",
 *             "stock_next": "2.000",
 *             "status": -5, // -4无单退货,-5无单换货
 *             "created": 1638326246,
 *             "updated": 1638326246
 *         },
 *         {
 *             "order_id": 787,
 *             "goods_id": 1570,
 *             "goods_name": "小米锅巴（大袋）",
 *             "barcode": "6970411499226",
 *             "amount": "-1.000",
 *             "selling_price": "5.00",
 *             "spec_typ": 0,
 *             "is_input_price": 0,
 *             "is_discount": 0,
 *             "subtotal_raw": "-5.00000",
 *             "subtotal": "-5.00",
 *             "stock_prev": "2.000",
 *             "stock_next": "3.000",
 *             "status": -4,
 *             "created": 1638326246,
 *             "updated": 1638326246
 *         }
 *     ],
 *     "shop": {
 *         "shop_name": "新天地超市",
 *         "shop_phone": "13444444444",
 *         "shop_address": "太原街18号"
 *     },
 *     "refund_amount": "5"
 * }
 */
